package javaBasic.javaSE1.Basic;

public class multiplicationTable {

    public static void main(String[] args) {
        table(11);
        niubi("=====");
        untable(11);
    }

    public static void table(int num){
        for (int i=1;i <= num;i++){
            for (int j=1;j <= i; j++){
                int temp = i*j;
                System.out.print(i+"*"+j+"="+ temp+"\t");
            }
            System.out.print("\n");
        }
    }

    public static void niubi(String niu){
        for (int i = 1;i<=20;i++){
            System.out.print(niu);
        }
        System.out.print(">\n");

    }

    public static void untable(int num){
        for (int i=num;i >= 1; i--){
            for (int j=1;j <= i; j++){
                int temp = i*j;
                System.out.print(i+"*"+j+"="+ temp+"\t");
            }
            System.out.print("\n");
        }
    }
}
